package com.yc.fav.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.util.List;

/**
 * <p>
 * 云收藏-标签表-5
 * </p>
 *
 * @author wz
 * @since 2022-11-06
 */
@TableName("fav_tag")
public class FavTag implements Serializable {
    //mybatis-plus 默认会认定实体类中每个属性都映射为数据库表字段
    //设置该属性不是数据库字段
    @TableField(exist = false)
    private List<FavFavorite> favorites;

    public List<FavFavorite> getFavorites(){
        return favorites;
    }
    public void setFavorites(List<FavFavorite> favorites){
        this.favorites =favorites;
    }

    private static final long serialVersionUID = 1L;

    /**
     * 编号: 自增列
     */
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    /**
     * 标签名: 根据收藏网站的 ftag 生成
     */
    private String tname;

    /**
     * 网站数: 属于该标签的网站数
     */
    private Integer tcount;


    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getTname() {
        return tname;
    }

    public void setTname(String tname) {
        this.tname = tname;
    }

    public Integer getTcount() {
        return tcount;
    }

    public void setTcount(Integer tcount) {
        this.tcount = tcount;
    }

    @Override
    public String toString() {
        return "FavTag{" +
        "id=" + id +
        ", tname=" + tname +
        ", tcount=" + tcount +
        "}";
    }
}
